package ua.com.m1995.client;

public class DBFStructureAdapterAK001 extends DBFStructureAdapter {

	/**
	 * Adapter's signature.
	 */
	private static final String[] ARRAY_OF_COLUMNS = {
		"NAME:N3; TYPE:N; OFFSET:1; LENGTH:12; DECIMAL:0;",
		"NAME:KOMN; TYPE:C; OFFSET:13; LENGTH:1; DECIMAL:0;",
		"NAME:PLANIR; TYPE:C; OFFSET:14; LENGTH:2; DECIMAL:0;",
		"NAME:RASPOL; TYPE:C; OFFSET:16; LENGTH:21; DECIMAL:0;",
		"NAME:MASIV; TYPE:C; OFFSET:37; LENGTH:25; DECIMAL:0;",
		"NAME:CENA; TYPE:N; OFFSET:62; LENGTH:9; DECIMAL:0;",
		"NAME:STREET; TYPE:C; OFFSET:71; LENGTH:30; DECIMAL:0;",
		"NAME:DOM_N; TYPE:C; OFFSET:101; LENGTH:7; DECIMAL:0;",
		"NAME:DATS; TYPE:D; OFFSET:108; LENGTH:8; DECIMAL:0;",
		"NAME:PL_O; TYPE:N; OFFSET:116; LENGTH:5; DECIMAL:1;",
		"NAME:PL_J; TYPE:N; OFFSET:121; LENGTH:5; DECIMAL:1;",
		"NAME:PL_K; TYPE:N; OFFSET:126; LENGTH:5; DECIMAL:1;",
		"NAME:ETAJ; TYPE:N; OFFSET:131; LENGTH:2; DECIMAL:0;",
		"NAME:ETAJA; TYPE:N; OFFSET:133; LENGTH:2; DECIMAL:0;",
		"NAME:DOM; TYPE:C; OFFSET:135; LENGTH:2; DECIMAL:0;",
		"NAME:T; TYPE:C; OFFSET:137; LENGTH:1; DECIMAL:0;",
		"NAME:TV; TYPE:C; OFFSET:138; LENGTH:1; DECIMAL:0;",
		"NAME:HOL; TYPE:C; OFFSET:139; LENGTH:1; DECIMAL:0;",
		"NAME:MEB; TYPE:C; OFFSET:140; LENGTH:1; DECIMAL:0;",
		"NAME:SA; TYPE:C; OFFSET:141; LENGTH:4; DECIMAL:0;",
		"NAME:TELEFON; TYPE:N; OFFSET:145; LENGTH:7; DECIMAL:0;",
		"NAME:INFORMATIO; TYPE:C; OFFSET:152; LENGTH:80; DECIMAL:0;",
		"NAME:N1; TYPE:N; OFFSET:232; LENGTH:8; DECIMAL:0;",
		"NAME:N2; TYPE:N; OFFSET:240; LENGTH:8; DECIMAL:0;",
		"NAME:FIRMA; TYPE:C; OFFSET:248; LENGTH:20; DECIMAL:0;",
		"NAME:EX; TYPE:C; OFFSET:268; LENGTH:1; DECIMAL:0;",
		"NAME:S; TYPE:L; OFFSET:269; LENGTH:1; DECIMAL:0;",
		"NAME:FO; TYPE:C; OFFSET:270; LENGTH:4; DECIMAL:0;",
		"NAME:KOD; TYPE:N; OFFSET:274; LENGTH:4; DECIMAL:0;"
	};
	
	public String[] getArrayOfColumns() {
		return ARRAY_OF_COLUMNS;
	}
	
	public RealEstateObjectList readData(byte[] bytes) throws ProgramException {
		RealEstateObjectList list = new RealEstateObjectList();
		DBFStructureRowReader reader = new DBFStructureRowReaderAK001();
		reader.read(bytes, list, this);
		return list;
	}

}
